From: Dave Love Date: Thu, 23 Oct 2003 22:56:47 +0000 (+0000) Subject: (locale-charset-to-coding-system): X-Git-Tag: archive/raspbian/1%29.2+1-2+rpi1~1^2~25128 X-Git-Url: https://dgit.raspbian.org/%22http:/www.example.com/cgi/%22https:/www.github.com/%22bookmarks:///%22http:/www.example.com/cgi/%22https:/www.github.com/%22bookmarks:/?a=commitdiff_plain;h=3dd59e09a78c16d880ebad2b9a18968446a913f9;p=emacs.git (locale-charset-to-coding-system): Don't rely on nil being a coding system. --- diff --git a/lisp/international/mule-cmds.el b/lisp/international/mule-cmds.el index f29e11b8e26..fb918094d4c 100644 --- a/lisp/international/mule-cmds.el +++ b/lisp/international/mule-cmds.el @@ -1981,6 +1981,13 @@ of `buffer-file-coding-system' set by this function." ;; http://www.din.de/gremien/nas/nabd/iso3166ma/codlstp1/en_listp1.html. ;; CODESET and MODIFIER are implementation-dependent. + ;; jasonr comments: MS Windows uses three letter codes for + ;; languages instead of the two letter ISO codes that POSIX + ;; uses. In most cases the first two letters are the same, so + ;; most of the regexps in locale-language-names work. Japanese + ;; and Chinese are exceptions, which are listed in the + ;; non-standard section at the bottom of locale-language-names. + ; aa Afar ; ab Abkhazian ("af" . "Latin-1") ; Afrikaans @@ -2235,7 +2242,7 @@ is returned. Thus, for instance, if charset \"ISO8859-2\", (if (locale-charset-match-p charset (caar cs)) (setq c (intern (caar cs))) (pop cs))) - (coding-system-base c)))) + (if c (coding-system-base c))))) ;; Fixme: This ought to deal with the territory part of the locale ;; too, for setting things such as calendar holidays, ps-print paper